<?php 
class AtmeModel extends Model{
    var $tableName = 'ts_atme';
    
    function addAtme($uids,$speech_id,$type){
	
		foreach ($uids as $v){
			$v = implode(' ',array_values($v));
			$sqlArr[] = "($v,$speech_id,'$type')";
			
			
			
		}
		$values = implode(',',$sqlArr);
		//print_r($values);
		if( $sqlArr ){
			$result = $this->query("INSERT INTO  ts_atme values $values ;" );
		}//".C('DB_PREFIX')."atme
		return $result;
    }
}
?>